tools/libxc: Correct use of X86_XSS_MASK in guest xstate generation
authorAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 19 Apr 2016 17:27:05 +0000 (18:27 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Wed, 20 Apr 2016 13:48:23 +0000 (14:48 +0100)
commit4e4689e74d012b737bbca820cfe52c689c7d9cef
tree4e0283c3047fd10c1becf64af8421d127e8aab9f
parent89534d87a42317448ab37b66315594080fc3c2ea
tools/libxc: Correct use of X86_XSS_MASK in guest xstate generation

c/s 75f9455e "tools/libxc: Calculate xstate cpuid leaf from guest information"
incorrectly inverted the shift and mask when using X86_XSS_MASK.  Luckily, the
mask is currently zero, avoiding incorrect calculations.

While adjusting this, use an explcit uint32_t cast rather than masking against
0xffffffff.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
Release-acked-by: Wei Liu <wei.liu2@citrix.com>
tools/libxc/xc_cpuid_x86.c